import { Subject, Observable } from 'rxjs'

const subject$ = new Subject()

subject$.subscribe((data) => console.log(`Subject 第一次订阅：${data}`))

subject$.next(1)
subject$.next(2)

subject$.subscribe((data) => console.log(`Subject 第二次订阅：${data}`))